<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="format-detection" content="telephone=no" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" />
    <meta name="apple-mobile-web-app-capable" content="yes" />
    <meta name="apple-mobile-web-app-status-bar-style" content="white" />
    <title></title>
    <link rel="stylesheet" href="../public/css/weui.css" />
    <link rel="stylesheet" href="../public/css/jquery-weui.min.css" />
    <link rel="stylesheet" href="../public/css/common.css" />
    <link rel="stylesheet" href="css/index.css" />
    <style type="text/css">
    	.millname-input.weui-input{
    		display: block;
    		border:0.02rem solid rgba(39,163,253,1);
    		font-size:0.32rem;
    		line-height: 0.9rem;
    		min-height: 0.9rem;
    		color: #555555;
    		height: 0.9rem;
    		border-radius: 0.5rem;
    		padding-left: 0.52rem;
    	}
    	.surebtn{
    		width:5.12rem;
			height:0.8rem;
			margin: auto;
			margin-top: 1.8rem;
			background:linear-gradient(138deg,rgba(39,163,253,1) 0%,rgba(24,119,248,1) 100%);
			opacity:1;
			border-radius:0.42rem;
			font-size:0.4rem;
			text-align: center;
			line-height: 0.8rem;
			color: #FFFFFF;
    	}
    </style>
</head>
<body style="background: #FFFFFF;">
<div id="millname">
	<div>
		<div style="height: 1.8rem;"></div>
		<div class="public_top_header">
			<a href="javascript:history.back(-1)" class="weui-cell">
				<div class="weui-cell__hd">
					<img src="../public/images/jiantouleft.png" />
				</div>
				<div class="weui-cell__bd">矿机名称</div>
			</a>
		</div>
	</div>
	<div style="margin: 0.74rem 0.5rem 0;">
		<input type="text" placeholder="请输入矿机名称" class="millname-input weui-input" v-model="newname"/>
	</div>
	<div class="surebtn" @click="confirm()">确认</div>
</div>
<script type="text/javascript" src="../public/js/jquery-2.1.4.js"></script>
<script type="text/javascript" src="../public/js/vue.js" ></script>
<script type="text/javascript" src="../public/js/jquery-weui.js" ></script>
<script type="text/javascript" src="../public/js/font_size.js" ></script>
<script type="text/javascript" src="../public/js/common.js" ></script>
<script type="text/javascript">
    $(function(){
        var vm = new Vue({
            el:"#millname",
            data: {
            	newname:""
            },
            methods:{
				confirm(){
				    console.log(getQueryParams(location.href).millid);
				    AjaxRequest({
						url:_url+"/money/mill/upmillname",
						load:true,
						data:{
                            newname:vm.newname,
							millid:getQueryParams(location.href).millid
						},
						type:"post",
						success(res){
						    location.href="./resetnamesuccess.html";
						}
					})
				}
            },
            created:function(){
            	
            }
        })
    })
</script>
</body>
</html>



